package com.hzdy.master.entity.table;

import com.fasterxml.jackson.annotation.JsonIgnore;
import com.hzdy.master.entity.Detail;
import lombok.Data;

import javax.persistence.*;
import java.io.Serializable;
import java.util.List;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: LALA
 * Date: 2019-03-08
 * Time: 11:15
 */
@Data
@Entity
@Table(name = "create_table")
public class CreateTable extends Detail implements Serializable {

    private String identifier;

    private String className;

    private String tableName;

    private String systemResource;

    private String updatePersonnel;

    private String createPersonnel;

    @OneToMany(
            cascade = CascadeType.ALL,
            fetch = FetchType.EAGER,
//            orphanRemoval = true
            mappedBy="createTable"
    )
    @JsonIgnore
    private List<FormField> formFields;



}
